package com.mrx.commons.exception;

import lombok.Getter;

/**
 * @author : 肖康宁
 * @since : 2022-12-09 14:19
 **/
@Getter
public class BusinessException extends RuntimeException {

    private final Object data;

    public BusinessException(String msg) {
        this(msg, null);
    }

    public BusinessException(Object data) {
        this("业务异常", data);
    }

    public BusinessException(String msg, Object data) {
        super(msg);
        this.data = data;
    }

}
